﻿@model PSU.Model.Areas.Administrator.Basic.ProfileViewModel
@{
    ViewData["Title"] = "个人中心";
    ViewData["NavTitle"] = "基础信息管理";
    ViewData["CurrName"] = "个人账户信息";
}

<section class="content-header">
    <h1>
        个人信息
        <small>Personal Center</small>
    </h1>
    <ol class="breadcrumb">
        <li>
            <a asp-area="Administrator" asp-controller="Home" asp-action="Index">
                <i class="fa fa-dashboard"></i> 首页
            </a>
        </li>
        <li>基础信息</li>
        <li class="active">个人信息</li>
    </ol>
</section>

<section class="content">
    <div class="row">
        <div class="col-md-3">
            <div class="box box-primary">
                <div class="box-body box-profile">
                    <img class="profile-user-img img-responsive img-circle" src="~/images/template/user2-160x160.jpg" alt="我的头像">
                    <h3 class="profile-username text-center">@Model.Name</h3>

                    <p class="text-muted text-center">系统管理员</p>

                    <ul class="list-group list-group-unbordered">
                        <li class="list-group-item">
                            <b>系统角色</b> <a class="pull-right">管理员</a>
                        </li>
                    </ul>

                    @*<a href="#" class="btn btn-primary btn-block"><b>更换头像</b></a>*@
                </div>
            </div>
        </div>
        <div class="col-md-9">
            <div class="box box-primary">
                <div class="box-body">
                    <div class="profile-user-info profile-user-info-striped">
                        <div class="profile-info-row">
                            <div class="profile-info-name"> 登录账户 </div>
                            <div class="profile-info-value">
                                <div class="col-md-12">
                                    <span class="editable editable-click">@Model.Account</span>
                                </div>
                            </div>
                        </div>
                        <div class="profile-info-row">
                            <div class="profile-info-name"> 联系地址 </div>
                            <div class="profile-info-value">
                                <div class="col-md-12">
                                    <div class="input-group">
                                        <input id="address" type="text" class="form-control" maxlength="200" asp-for="Address" />
                                        <div class="input-group-addon">
                                            <i class="fa fa-map-marker text-orange"></i>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="profile-info-row">
                            <div class="profile-info-name"> 工号 </div>
                            <div class="profile-info-value">
                                <div class="col-md-12">
                                    <span class="editable editable-click">@Model.Id</span>
                                </div>
                            </div>
                        </div>
                        <div class="profile-info-row">
                            <div class="profile-info-name"> 年龄 </div>
                            <div class="profile-info-value ">
                                <div class="col-md-3" style="display:inline-flex">
                                    <input id="age" type="number" class="form-control" maxlength="20" min="1" asp-for="Age" />
                                    <span style="margin:7px 0px 0px 5px;">岁</span>
                                </div>
                            </div>
                        </div>
                        <div class="profile-info-row">
                            <div class="profile-info-name"> 创建日期 </div>
                            <div class="profile-info-value">
                                <div class="col-md-12">
                                    <span class="editable editable-click" id="signup">@Model.CreateTime</span>
                                </div>
                            </div>
                        </div>
                        <div class="profile-info-row">
                            <div class="profile-info-name"> 性别 </div>
                            <div class="profile-info-value">
                                <div class="col-md-12">
                                    @if (Model.Gender)
                                    {
                                        <input type="radio" class="iradio_flat-green" name="gender" value="true" checked><span>男</span>
                                        <input type="radio" class="iradio_flat-green" name="gender" value="false"><span>女</span>
                                    }
                                    else
                                    {
                                        <input type="radio" class="iradio_flat-green" name="gender" value="true"><span>男</span>
                                        <input type="radio" class="iradio_flat-green" name="gender" value="false" checked><span>女</span>
                                    }
                                </div>
                            </div>
                        </div>
                        <div class="profile-info-row">
                            <div class="profile-info-name"> 手机号 </div>
                            <div class="profile-info-value">
                                <div class="col-md-4">
                                    <input id="phone" type="text" class="form-control" maxlength="20" asp-for="Phone" />
                                </div>
                            </div>
                        </div>
                        <div class="profile-info-row">
                            <div class="profile-info-name"> 电子邮箱 </div>
                            <div class="profile-info-value">
                                <div class="col-md-6">
                                    <input id="email" type="text" class="form-control" maxlength="20" asp-for="Email" />
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="box-footer">
                    <div class="text-right">
                        <a class="btn btn-success col-md-offset-2" id="save" data-id="@Model.Id">
                            <i class="fa fa-check"></i>
                            保存
                        </a>
                    </div>
                </div>
            </div>
        </div>
    </div>
</section>

@section scripts{
    <environment include="Development">
        <script src="~/javascript/view/Administrator/profile.js"></script>
    </environment>
    <environment exclude="Development">
        <script src="~/javascript/view/Administrator/profile.min.js" asp-append-version="true"></script>
    </environment>
}